package com.cqut.forum.service;

import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Controller;

import com.cqut.forum.entity.Article;
import com.cqut.forum.entity.User;

/**
 * 用户心情service接口
 * @author yangxun
 */
@Controller
public interface ActiveService {
	
	/**
	 * 用户发表心情
	 * @param userId 用户id
	 * @param content 用户心情
	 * @return 返回用户状态信息
	 */
	public Article addActive(Article article);
	
	public Article getArticle(int articleId);
	
	public List<Map<String, Object>> getHotArticle(int index,int size);
	
	public Article updateArticle(Article article);
	
	public List<Map<String, Object>> getByOwnerId(int userId,int index,int size);

	public List<Article> getByGroupId(int groupId,int index,int size);
	
	public List<Map<String, Object>> getByOwnerId(int userId,String keyWords,int index,int size);
	
	public String getArticleGroupName(int articleId);
	
	public List<User> getHotArticleUser(int index,int size);
	
	public List<Map<String, Object>> getArticleVisitor(int articleId);
	
	public List<Map<String, Object>> getModuleVisitors(int userId,int moduelId,int index,int size);
	
	public List<Map<String, Object>> getLastArticle(int index,int size,int moduleId);
	
	public List<Map<String, Object>> getArticleByCase(int userId,int moduleId,int index,int size,String option);
	public Map<String, Object> getNext(int articleId);
	public Map<String, Object> getPrevious(int articleId);
	
	public boolean haveReadMyArticle(int userId,String moduleName);
	
	public int count(int userId,String moduleName);
	
	public boolean deleteArticel(int userId,int targetId);
}
